/*-------------------------------------------------------------------------

***************** Modification History ***********************************
   @doc
   @module format.h - Header file for Data formating functions |
   @end
   
$Log: /SoftPay/SPK2SIM/Source/Utils/format.h $ 
**************************************************************************

   Copyright (C) 1999 by VeriFone, Inc.

   All rights reserved.  No part of this software may be reproduced,
   transmitted, transcribed, stored in a retrieval system, or translated
   into any language or computer language, in any form or by any means,
   electronic, mechanical, magnetic, optical, chemical, manual or otherwise,
   without the prior written permission of VeriFone, Inc.

---------------------------------------------------------------------------*/


#ifndef VSFORMAT
/* Padding defines */

#include <transact.h>

#define VS_LEFT            0
#define VS_RIGHT           1

extern void vdFormatDate (char *pchDate);
extern void vdFormatTime (char *pchTime);
extern void vdGetDate (char *pchDate, int inMode);
extern void MaskingMerchant(int Type, char * inpt,char *Output);

int inParseBuffer (char *pchBuf, char chSep, char *pVarPtrs[]);
void vdTrimSpaces (char *pchString);
void vdTrimLeadZeroes (char *pchString);
void vdTrimLeadSpaces (char *pchString);
void vdRemDecPoint (char *pchAmt);
void vdFormatPerCent (char *pchAmt, int inFractionalSize);
void vdFormatAmount (char *pchAmt, VS_BOOL fPutSymbol);
void vdFormatPAN (TRANSACTION_OBJECT *pobTran, char *pchPAN, char *pchFmtPAN, int inFmtPANSize);
void vdFormatDate (char *pchDate);
void vdFormatTime (char *pchTime);
void vdPurgeStrofChars (char *pchInString, char *pchCharstoRemove);
char formatAmt(char *into, char*amt,char *currency, char *format, VS_BOOL print);

/* CVision stuff Simon_h2 */

struct date_type
{
	unsigned char day, month;
	unsigned int year;
};


void date_to_string(char *str, char *format, struct date_type *buffer);
struct date_type *string_to_date(char *str, char *format);

#define VSFORMAT_H
#endif /* VSFORMAT_H */
